3.2.79 \(\int (g \cos (e+f x))^{-3-2 m} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^n \, dx\) [179]

Optimal. Leaf size=85 \[ \frac {c (g \cos (e+f x))^{-2 m} \, _2F_1\left (2,-1-m+n;-m+n;\frac {1}{2} (1-\sin (e+f x))\right ) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-1+n}}{4 f g^3 (1+m-n)} \]

[Out]

1/4*c*hypergeom([2, -1-m+n],[-m+n],1/2-1/2*sin(f*x+e))*(a+a*sin(f*x+e))^m*(c-c*sin(f*x+e))^(-1+n)/f/g^3/(1+m-n
)/((g*cos(f*x+e))^(2*m))

________________________________________________________________________________________

Rubi [A]
time = 0.17, antiderivative size = 85, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 40, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {2932, 12, 2746, 70} \begin {gather*} \frac {c (a \sin (e+f x)+a)^m (c-c \sin (e+f x))^{n-1} (g \cos (e+f x))^{-2 m} \, _2F_1\left (2,-m+n-1;n-m;\frac {1}{2} (1-\sin (e+f x))\right )}{4 f g^3 (m-n+1)} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(g*Cos[e + f*x])^(-3 - 2*m)*(a + a*Sin[e + f*x])^m*(c - c*Sin[e + f*x])^n,x]

[Out]

(c*Hypergeometric2F1[2, -1 - m + n, -m + n, (1 - Sin[e + f*x])/2]*(a + a*Sin[e + f*x])^m*(c - c*Sin[e + f*x])^
(-1 + n))/(4*f*g^3*(1 + m - n)*(g*Cos[e + f*x])^(2*m))

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 70

Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(b*c - a*d)^n*((a + b*x)^(m + 1)/(b^(
n + 1)*(m + 1)))*Hypergeometric2F1[-n, m + 1, m + 2, (-d)*((a + b*x)/(b*c - a*d))], x] /; FreeQ[{a, b, c, d, m
}, x] && NeQ[b*c - a*d, 0] &&  !IntegerQ[m] && IntegerQ[n]

Rule 2746

Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Dist[1/(b^p*f), S
ubst[Int[(a + x)^(m + (p - 1)/2)*(a - x)^((p - 1)/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x]
&& IntegerQ[(p - 1)/2] && EqQ[a^2 - b^2, 0] && (GeQ[p, -1] ||  !IntegerQ[m + 1/2])

Rule 2932

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*sin[(e_.) +
 (f_.)*(x_)])^(n_), x_Symbol] :> Dist[a^IntPart[m]*c^IntPart[m]*(a + b*Sin[e + f*x])^FracPart[m]*((c + d*Sin[e
 + f*x])^FracPart[m]/(g^(2*IntPart[m])*(g*Cos[e + f*x])^(2*FracPart[m]))), Int[(g*Cos[e + f*x])^(2*m + p)*(c +
 d*Sin[e + f*x])^(n - m), x], x] /; FreeQ[{a, b, c, d, e, f, g, m, n, p}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 -
 b^2, 0] && (FractionQ[m] ||  !FractionQ[n])

Rubi steps

\begin {align*} \int (g \cos (e+f x))^{-3-2 m} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^n \, dx &=\left ((g \cos (e+f x))^{-2 m} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^m\right ) \int \frac {\sec ^3(e+f x) (c-c \sin (e+f x))^{-m+n}}{g^3} \, dx\\ &=\frac {\left ((g \cos (e+f x))^{-2 m} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^m\right ) \int \sec ^3(e+f x) (c-c \sin (e+f x))^{-m+n} \, dx}{g^3}\\ &=-\frac {\left (c^3 (g \cos (e+f x))^{-2 m} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^m\right ) \text {Subst}\left (\int \frac {(c+x)^{-2-m+n}}{(c-x)^2} \, dx,x,-c \sin (e+f x)\right )}{f g^3}\\ &=\frac {c (g \cos (e+f x))^{-2 m} \, _2F_1\left (2,-1-m+n;-m+n;\frac {1}{2} (1-\sin (e+f x))\right ) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-1+n}}{4 f g^3 (1+m-n)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 36.63, size = 135, normalized size = 1.59 \begin {gather*} \frac {(g \cos (e+f x))^{-2 m} \cot ^2\left (\frac {1}{4} (2 e-\pi +2 f x)\right ) \, _2F_1\left (-2-m+n,-1-m+n;-m+n;-\tan ^2\left (\frac {1}{4} (2 e-\pi +2 f x)\right )\right ) \sec ^2\left (\frac {1}{4} (2 e-\pi +2 f x)\right )^{-m+n} (a (1+\sin (e+f x)))^m (c-c \sin (e+f x))^n}{8 f g^3 (1+m-n)} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(g*Cos[e + f*x])^(-3 - 2*m)*(a + a*Sin[e + f*x])^m*(c - c*Sin[e + f*x])^n,x]

[Out]

(Cot[(2*e - Pi + 2*f*x)/4]^2*Hypergeometric2F1[-2 - m + n, -1 - m + n, -m + n, -Tan[(2*e - Pi + 2*f*x)/4]^2]*(
Sec[(2*e - Pi + 2*f*x)/4]^2)^(-m + n)*(a*(1 + Sin[e + f*x]))^m*(c - c*Sin[e + f*x])^n)/(8*f*g^3*(1 + m - n)*(g
*Cos[e + f*x])^(2*m))

________________________________________________________________________________________

Maple [F]
time = 0.14, size = 0, normalized size = 0.00 \[\int \left (g \cos \left (f x +e \right )\right )^{-3-2 m} \left (a +a \sin \left (f x +e \right )\right )^{m} \left (c -c \sin \left (f x +e \right )\right )^{n}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((g*cos(f*x+e))^(-3-2*m)*(a+a*sin(f*x+e))^m*(c-c*sin(f*x+e))^n,x)

[Out]

int((g*cos(f*x+e))^(-3-2*m)*(a+a*sin(f*x+e))^m*(c-c*sin(f*x+e))^n,x)

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*cos(f*x+e))^(-3-2*m)*(a+a*sin(f*x+e))^m*(c-c*sin(f*x+e))^n,x, algorithm="maxima")

[Out]

integrate((g*cos(f*x + e))^(-2*m - 3)*(a*sin(f*x + e) + a)^m*(-c*sin(f*x + e) + c)^n, x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*cos(f*x+e))^(-3-2*m)*(a+a*sin(f*x+e))^m*(c-c*sin(f*x+e))^n,x, algorithm="fricas")

[Out]

integral((g*cos(f*x + e))^(-2*m - 3)*(a*sin(f*x + e) + a)^m*(-c*sin(f*x + e) + c)^n, x)

________________________________________________________________________________________

Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*cos(f*x+e))**(-3-2*m)*(a+a*sin(f*x+e))**m*(c-c*sin(f*x+e))**n,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*cos(f*x+e))^(-3-2*m)*(a+a*sin(f*x+e))^m*(c-c*sin(f*x+e))^n,x, algorithm="giac")

[Out]

integrate((g*cos(f*x + e))^(-2*m - 3)*(a*sin(f*x + e) + a)^m*(-c*sin(f*x + e) + c)^n, x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+a\,\sin \left (e+f\,x\right )\right )}^m\,{\left (c-c\,\sin \left (e+f\,x\right )\right )}^n}{{\left (g\,\cos \left (e+f\,x\right )\right )}^{2\,m+3}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((a + a*sin(e + f*x))^m*(c - c*sin(e + f*x))^n)/(g*cos(e + f*x))^(2*m + 3),x)

[Out]

int(((a + a*sin(e + f*x))^m*(c - c*sin(e + f*x))^n)/(g*cos(e + f*x))^(2*m + 3), x)

________________________________________________________________________________________